﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using XMLSpreadGear.Core;

namespace XMLSpreadGear.Headers
{
   public class NumberFormat:BaseElement
    {
        public NumberFormat()
            : base(LocalNames.NUMBERFORMAT)
        {

        }

        public NumberFormat(string format)
            : this()
        {
            this.Format = format;
        }

        string m_Format;
        public string Format
        {
            get { return m_Format; }
            set { m_Format = value; }
        }

        internal protected override IDictionary<string, string> RegisterAttributes()
        {
            IDictionary<string, string> dic = new Dictionary<string, string>();
            dic.Add("Format", this.Format.ToString());
            return dic;
        }

        internal protected override IDictionary<string, string> RegisterElements()
        {
            IDictionary<string, string> dic = new Dictionary<string, string>();
            return dic;
        }

        internal override string GetAttributeNamespace()
        {
            return Contstants.SpredsheetAttributePrefix;
        }

        internal override string GetAttributeNamespaceURI()
        {
            return Contstants.SpredsheetAttributeNamespace;
        }

        protected override void SetDefaults()
        {
            return;
        }
    }
}
